import { createApp } from "vue";
import App from "./App.vue";
import store from "@/store";
import router from "@/router";
// 公用css 重置基本样式、公用样式
import "@/assets/css/global.scss";
import utils from "@/utils/utils";
// 与原生交互
import wondersh5 from "@/assets/js/wondersh5";

// 公用头部
import webHeader from "@/components/WebHeader/WebHeader.vue";

import {
	Button,
	Empty,
	Toast,
	Field,
	Icon,
	List,
	PullRefresh,
	Search,
	Tab,
	Tabs,
	Popup,
	Picker,
	DatePicker,
	CheckboxGroup,
	Checkbox,
	Grid,
	GridItem,
	Swipe,
	SwipeItem,
	Cascader,
	Dialog,
	Step,
	Steps,
	ImagePreview
} from "vant";
import "vant/lib/index.css";
import "@/assets/css/global.scss";
const app = createApp(App);
app.config.globalProperties.$utils = utils;
app.config.globalProperties.$wondersh5 = wondersh5;
app.component("WebHeader", webHeader);
app
	.use(Button)
	.use(Icon)
	.use(Search)
	.use(List)
	.use(PullRefresh)
	.use(Tab)
	.use(Tabs)
	.use(Popup)
	.use(Empty)
	.use(Field)
	.use(Picker)
	.use(DatePicker)
	.use(CheckboxGroup)
	.use(Checkbox)
	.use(Grid)
	.use(GridItem)
	.use(Cascader)
	.use(Dialog)
	.use(Swipe)
	.use(SwipeItem)
	.use(Toast)
	.use(Step)
	.use(Steps)
	.use(ImagePreview);
app.use(router);
app.use(store);

app.mount("#app");
